package com.ss.android.account.e;

import android.os.Handler;
import android.os.Looper;
import com.ss.android.account.v2.c.d;
import java.util.Timer;
import java.util.TimerTask;

public final class b {
    public static final class a {
        public final d a;

        public a(d arg1) {
            this.a = arg1;

        }
    }

    public static final class b$b extends TimerTask {
        private final b a;

        private b$b(b arg1) {
            this.a = arg1;

        }

        public b$b(b arg1, byte arg2) {
            this(arg1);
        }

        public final void run() {
            --this.a.b;
            if(this.a.d != null) {
                this.a.c.post(this.a.e);
            }

            if(this.a.b <= 0) {
                this.a.a.cancel();
            }
        }
    }

    public Timer a;
    public int b;
    Handler c;
    a d;
    Runnable e;

    public b(a arg3) {

        this.e = new c(this);
        this.d = arg3;
        this.c = new Handler(Looper.getMainLooper());
    }

    public final void a() {
        if(this.b > 0 && this.a != null) {
            this.a.cancel();
            this.a = null;
        }
    }
}

